import axios from 'axios'
import MockAdapter from 'axios-mock-adapter'
import user from './user'
import Mock from 'mockjs'
export default {
    analog() {
        let mock = new MockAdapter(axios)

        mock.restore();//暂停模仿

        mock.onGet('/find/list').reply(user.list)
        mock.onGet('/find/ratelist').reply(user.ratelist)
        mock.onGet('/find/melist').reply(user.melist)
        mock.onGet('/find/addComment').reply(user.addComment)
        mock.onGet('/find/addReply').reply(user.addReply)
        mock.onGet('/find/changeLike').reply(user.changeLike)
        // mock error request
        mock.onGet('/error').reply(500, {
            msg: 'failure'
        })


    }
}